#导入redis
import redis



class RedisCon:
    def __init__(self):
        self.r=redis.Redis(host='localhost',port=6379,db=1)

    #存set
    def insert_set(self,key,val):
        self.r.sadd(key,*val)
    #取set
    def find_set(self,key):
        val=self.r.smembers(key)
        if val:
            print(val)
        else:
            return None

red=RedisCon()

